package com.huluobo.day11_im.addGroup.presenter;

import com.hyphenate.chat.EMGroupInfo;
import com.hyphenate.chat.EMGroupOptions;

import java.util.List;

public interface AddGroupContract {
    interface Presenter {
        //groupName, desc, allMembers, reason, option
        void createGroup(String groupName, String desc, String[] users, String reason,
                         EMGroupOptions emGroupOptions);

        void findAllGroups(int pageSize, String cursor);

        void joinGroup(String groupId);
    }

    interface View {
        void onCreateGroupSuccess();

        void onCreateGroupFailed(String error);

        void onFindAllGroupsSuccess(List<EMGroupInfo> groupsList);

        void onFindAllGroupsFailed(String error);

        void onJoinGroupSuccess();

        void onJoinGroupFailed(String error);
    }
}
